<div class="tableform">
      <table cellspacing="0" cellpadding="0" border="0" class="gridlist">
        <tr>
              <th>物料</th>
              <th>物料名称</th>
              <th>活动开始时间</th>
              <th>活动结束时间</th>
              <th>价格条件</th>
              <th>价格</th>
              <th>差价</th>
        </tr>
    <{assign var="key" value="0"}>
      <{foreach from=$res item=his}>
      <{assign var="key" value=$key+1 }>
      <tbody>
        <tr>
          <td><{$his.bn}></td>
          <td><{$his.product_name}></td>
          <td><{$his.begin_date}></td>
          <td><{$his.end_date}></td>
          <td><{ if $his.cod =='0' }>小于<{elseif $his.cod=='1'}>小于等于<{elseif $his.cod=='2'}>等于<{/if}></td>
          <td><{$his.price}></td>
          <td><{$his.diffprice}></td>
          </tr>
        </tbody>
      <{/foreach}>
        <tr>
          <td>总数：</td>
          <td colspan="6"><{$key}></td>
        </tr>
      </table>
</div>